#by SNWCreations

#update: choose team is easy now.
execute if score gameState stats matches 0 as @e[type=item,nbt={Item:{tag:{HunterTeam:1}}}] at @s as @p run function hunterplus:be_hunter
execute if score gameState stats matches 0 as @e[type=item,nbt={Item:{tag:{HunterTeam:2}}}] at @s as @p run function hunterplus:be_runner



execute if score gameState stats matches 1 as @a[team=runner] at @s run setworldspawn ~ ~ ~
execute as @a[team=hunter] if score @s death matches 1 run function hunterplus:hunter_respawn
